<!DOCTYPE HTML>
<html lang="en">
<#include "../common/head.html"/>
<body>
<section class="content">
  <#include "../common/messageTip.html"/>
  <div class="row">
    <div class="col-md-6 col-md-offset-3">
      <div class="box box-primary">
        <div class="box-header with-border">
          <h3 class="box-title">${(!room.id??)?string('添加','修改')}教室</h3>
        </div>
        <div class="box-body">
          <form class="form-horizontal js-ajax-form" action="/console/room/merge" method="post">
            <input type="hidden" name="id" id="id" value="${room.id!}"/>
            <div class="form-group">
              <label class="col-sm-2 control-label">教学楼</label>
              <div class="col-sm-10">
                <select name="floorId" class="form-control">
                  <#list floorList as item>
                    <option value="${item.id}" <#if item.id == room.floorId!0>selected</#if>>${item.name}</option>
                  </#list>
                </select>
              </div>
            </div>

            <div class="form-group">
              <label class="col-sm-2 control-label">名字</label>
              <div class="col-sm-10">
                <input type="text" name="name" class="form-control" value="${room.name!}"/>
              </div>
            </div>
            <div class="form-group">
              <label class="col-sm-2 control-label">地址</label>
              <div class="col-sm-10">
                <input type="text" name="address" class="form-control" value="${room.address!}"/>
              </div>
            </div>
            <div class="form-group">
              <label class="col-sm-2 control-label">楼层</label>
              <div class="col-sm-10">
                <select name="floor" class="form-control">
                  <option value="一楼" <#if "一楼"== room.floor!>selected</#if>>一楼</option>
                  <option value="二楼" <#if "二楼"== room.floor!>selected</#if>>二楼</option>
                  <option value="三楼" <#if "三楼"== room.floor!>selected</#if>>三楼</option>
                  <option value="四楼" <#if "四楼"== room.floor!>selected</#if>>四楼</option>
                  <option value="五楼" <#if "五楼"== room.floor!>selected</#if>>五楼</option>
                  <option value="六楼" <#if "六楼"== room.floor!>selected</#if>>六楼</option>
                  <option value="七楼" <#if "七楼"== room.floor!>selected</#if>>七楼</option>
                  <option value="八楼" <#if "八楼"== room.floor!>selected</#if>>八楼</option>
                  <option value="九楼" <#if "九楼"== room.floor!>selected</#if>>九楼</option>
                </select>
              </div>
            </div>
            <div class="form-group">
              <label class="col-sm-2 control-label">规模</label>
              <div class="col-sm-10">
                <select name="scale" class="form-control">
                    <option value="小教室(40人)" <#if '小教室(40人)' == room.scale!''>selected</#if>>小教室(40人)</option>
                    <option value="中教室(80人)" <#if '中教室(80人)' == room.scale!''>selected</#if>>中教室(80人)</option>
                    <option value="大教室(200人)" <#if '大教室(200人)' == room.scale!''>selected</#if>>大教室(200人)</option>
                    <option value="大学生活动中心" <#if '大学生活动中心' == room.scale!''>selected</#if>>大学生活动中心</option>
                    <option value="礼堂" <#if '礼堂' == room.scale!''>selected</#if>>礼堂</option>
                </select>
              </div>
            </div>
            <div class="form-group">
              <label class="col-sm-2 control-label">星期一</label>
              <div class="col-sm-10">
                <label class="checkbox-inline"><input type="checkbox" name="week1" <#if room.week1!?contains("1"?string)>checked</#if> value="1">上午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week1" <#if room.week1!?contains("2"?string)>checked</#if> value="2">上午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week1" <#if room.week1!?contains("3"?string)>checked</#if> value="3">下午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week1" <#if room.week1!?contains("4"?string)>checked</#if> value="4">下午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week1" <#if room.week1!?contains("5"?string)>checked</#if> value="5">晚上第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week1" <#if room.week1!?contains("6"?string)>checked</#if> value="6">晚上第二大节</label>
              </div>
            </div>
            <div class="form-group">
              <label class="col-sm-2 control-label">星期二</label>
              <div class="col-sm-10">
                <label class="checkbox-inline"><input type="checkbox" name="week2" <#if room.week2!?contains("1"?string)>checked</#if> value="1">上午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week2" <#if room.week2!?contains("2"?string)>checked</#if> value="2">上午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week2" <#if room.week2!?contains("3"?string)>checked</#if> value="3">下午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week2" <#if room.week2!?contains("4"?string)>checked</#if> value="4">下午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week2" <#if room.week1!?contains("5"?string)>checked</#if> value="5">晚上第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week2" <#if room.week1!?contains("6"?string)>checked</#if> value="6">晚上第二大节</label>
              </div>
            </div><div class="form-group">
              <label class="col-sm-2 control-label">星期三</label>
              <div class="col-sm-10">
                <label class="checkbox-inline"><input type="checkbox" name="week3" <#if room.week3!?contains("1"?string)>checked</#if> value="1">上午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week3" <#if room.week3!?contains("2"?string)>checked</#if> value="2">上午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week3" <#if room.week3!?contains("3"?string)>checked</#if> value="3">下午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week3" <#if room.week3!?contains("4"?string)>checked</#if> value="4">下午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week3" <#if room.week1!?contains("5"?string)>checked</#if> value="5">晚上第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week3" <#if room.week1!?contains("6"?string)>checked</#if> value="6">晚上第二大节</label>
              </div>
            </div><div class="form-group">
              <label class="col-sm-2 control-label">星期四</label>
              <div class="col-sm-10">
                <label class="checkbox-inline"><input type="checkbox" name="week4" <#if room.week4!?contains("1"?string)>checked</#if> value="1">上午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week4" <#if room.week4!?contains("2"?string)>checked</#if> value="2">上午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week4" <#if room.week4!?contains("3"?string)>checked</#if> value="3">下午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week4" <#if room.week4!?contains("4"?string)>checked</#if> value="4">下午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week4" <#if room.week1!?contains("5"?string)>checked</#if> value="5">晚上第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week4" <#if room.week1!?contains("6"?string)>checked</#if> value="6">晚上第二大节</label>
              </div>
            </div><div class="form-group">
              <label class="col-sm-2 control-label">星期五</label>
              <div class="col-sm-10">
                <label class="checkbox-inline"><input type="checkbox" name="week5" <#if room.week5!?contains("1"?string)>checked</#if> value="1">上午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week5" <#if room.week5!?contains("2"?string)>checked</#if> value="2">上午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week5" <#if room.week5!?contains("3"?string)>checked</#if> value="3">下午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week5" <#if room.week5!?contains("4"?string)>checked</#if> value="4">下午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week5" <#if room.week1!?contains("5"?string)>checked</#if> value="5">晚上第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week5" <#if room.week1!?contains("6"?string)>checked</#if> value="6">晚上第二大节</label>
              </div>
            </div><div class="form-group">
              <label class="col-sm-2 control-label">星期六</label>
              <div class="col-sm-10">
                <label class="checkbox-inline"><input type="checkbox" name="week6" <#if room.week6!?contains("1"?string)>checked</#if> value="1">上午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week6" <#if room.week6!?contains("2"?string)>checked</#if> value="2">上午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week6" <#if room.week6!?contains("3"?string)>checked</#if> value="3">下午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week6" <#if room.week6!?contains("4"?string)>checked</#if> value="4">下午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week6" <#if room.week1!?contains("5"?string)>checked</#if> value="5">晚上第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week6" <#if room.week1!?contains("6"?string)>checked</#if> value="6">晚上第二大节</label>
              </div>
            </div><div class="form-group">
              <label class="col-sm-2 control-label">星期日</label>
              <div class="col-sm-10">
                <label class="checkbox-inline"><input type="checkbox" name="week7" <#if room.week7!?contains("1"?string)>checked</#if> value="1">上午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week7" <#if room.week7!?contains("2"?string)>checked</#if> value="2">上午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week7" <#if room.week7!?contains("3"?string)>checked</#if> value="3">下午第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week7" <#if room.week7!?contains("4"?string)>checked</#if> value="4">下午第二大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week7" <#if room.week1!?contains("5"?string)>checked</#if> value="5">晚上第一大节</label>
                <label class="checkbox-inline"><input type="checkbox" name="week7" <#if room.week1!?contains("6"?string)>checked</#if> value="6">晚上第二大节</label>
              </div>
            </div>

            <div class="form-group">
              <div class="col-sm-offset-2 col-sm-10">
                <button type="submit" class="btn btn-default">提交</button>
              </div>
            </div>
          </form>
        </div>
      </div>
    </div>
  </div>
</section>
<#include "../common/footer.html"/>

</body>
</html>